package univer.oko.testcases.simple;

import junit.framework.Test;
import junit.framework.TestSuite;

import java.rmi.RemoteException;

/**
 * @author Eduard Dudar
 *         Date: 08.11.2005
 *         Time: 0:31:57
 */
public class PaymentYearTest extends SimpleODBCTest {
    protected static final int INDEX = 5;
    protected static final String NAME = "2003/2004";

    public static Test suite() {
        return new TestSuite(PaymentYearTest.class);
    }

    public void testGetPaymentYearName() {
        try {
            assertTrue(this.rmi.getPaymentYear(INDEX).equals("2004/2005"));
        }
        catch (RemoteException e) {
            throw new RuntimeException(e);
        }
    }

    public void testGetPaymentYearID() {
        try {
            assertTrue(this.rmi.getPaymentYearID(NAME) == 4);
        }
        catch (RemoteException e) {
            throw new RuntimeException(e);
        }
    }
}